How do you implement a query that examines if a line is connected at both ends?

Hey all,
I want to write a query that examines if a line is connected at both ends (a very common rule in the area of topology) but I cannot seem to find an easy way to do so. (By connected I mean that there is another line that 'touches' the given line.)
The problem I have is that I cannot find any way to retrieve the start or end point of a line geometry. (I am using Oracle 8.1.7.)
If someone can give me any suggestions I would be very grateful.
Thanks in advance,
Johan Behrenfeldt

Hey,
Thanks for both of the answers.
I eventually solved the problem using Java stored procedures. However, in the case that someone is looking for the answer to the same question I was asking I just wanted to point out a few things.
Jens' solution seems correct and it was my first approach as well. However, there is a case when it fails and that is if the lines connect in the shape of a triangle. You would find a line that has connected lines at both ends but the connected lines would have a non-empty intersection and would therefore be discarded incorrectly.
The second suggested solution works, but I have found it less than trivial to find the ordinate tuple that contains the start point of the line string. Many GIS applications insists on using the ordinate array as a storage place for data. They will use the sdo_etype 0 to hide the information from Spatial, but when manipulating the geometries manually they cause a great deal of trouble. (Try writing an sql query to retrieve the start point of a line.)
The latter is, however, what I ended up using in the end. With the help of Java stored procedures the task became fairly easy.
Thank you, in any case, for all your help, and I apologize if I come off as a smart-allick here. ;-)
Johan Behrenfeldt

Similar Messages

  • How do you find a table that doesn't have a specific word in it.

    I have two questions.
    questions 1
    How do you find a table that doesn't have a specific word in it by using a query on the whole database?
    questions 2
    How would i list all of my cars names in my database not showing duplicates?
    I have tried, tried and tried some more to get both of these, but I guess i don't know how to query a specific word.
    I also don't know how to query everything in just 1 column name.
    If anyone could help with these that would be great I have been trying queries for over an hour now and no luck.
    Thanks

    798837 wrote:
    I tried the all_tab_columns, just like you did it, however that just gives me the column name I am looking for what is not in a column.
    For example I need to find all the tables where mustang is not = 'red' but using a single query i need to find all of the tables.
    As for number 2
    I am looking for something like this
    select distinct column_name
    from all_tab_columns
    where column_name ='AcertainColumn';Now I'm even more confused. In your example, is MUSTANG a column name? Or is it the value of a MODEL column in the CARS table? And how could that possibly relate to something that exists in multiple tables?
    If your data model is at all reasonable, I would expect that you would just want
    SELECT *
      FROM cars
    WHERE model = 'Mustang'
       AND color != 'Red'but I can't see how this would relate to data stored in multiple tables.
    Justin

  • How would you implement equals ()

    For complex classes with many data members, my dilema is:
    1. equals should return true only if all fields of the two objects are
    equals.
    2. equals should return true if the key(s) of the two objets are equal.
    For instance, we have the Class Person, that contains dozens of
    data: ID, name, age, job, salary, children, more 1000 items.
    Person is like a record in a DB table. There can not be two persons
    with the same ID.
    In this case, how would you implement equals, and why?
    thanks

    What I'm trying to say is: what is equality foryou?
    Two objects are equal if all there contents areequals
    or is it enough
    to compare their keys?
    In the latter case, there can happen, by somereason,
    that we can end
    up with two objects with the same keys, but all the
    rest of
    the contents different.i think you meant to say that:
    In the latter case, there can happen, by somereason,
    that we can end
    up with two objects with different keys, but
    all the rest of the contents the same.and the answer is, and listen carefully, it totally
    depends on the application you are writing. there
    is no hard definition of equality where custom classes
    are concerned... that is the answer.If this question arises, you should revisit your design.
    If two entities have equal keys, they should be considered to be equal. Otherwise the attributes you call keys are in the fact normal attributes and no keys.

  • No longer use this email account but how do you backup the email that is...

    No longer use this email account but how do you backup the email that is in the "example" folder, So that I can delete the account on my mail app?

    Not sure what you mean. Deleting a POP account only deletes the messages stored in the account’s mailboxes, not any messages stored in custom “On My Mac” mailboxes, if that’s what you mean. It’s not that Mail goes after your mail trying to delete as much as it can. It’s just that if a mail account is deleted, then its mailboxes cannot exist anymore...
    That said, instead of deleting the account right away, you can just disable it (i.e. turn OFF Preferences > Accounts > Advanced > Enable this account), leave it that way for some time, and delete it only after making sure you didn’t miss anything while the account was disabled.
    BTW, if you back up your data, and the ~/Library/Mail folder in particular, you won’t have to worry about accidentally losing anything as a result of doing something like that...
    Note: For those not familiarized with the ~/ notation, it refers to the user’s home folder. That is, ~/Library is the Library folder within the user’s home folder, i.e. /Users/username/Library.

  • How do you fix an ipod that has a black screen and it turns on but when it turns on the screen gets a lighter black but you still can't see the apps or anything?

    How do you fix an ipod that has a black screen and it turns on but when it turns on the screen gets a lighter black but you still can't see the apps or anything?

    Try:
    - Reset the iOS device. Nothing will be lost
    Reset iOS device: Hold down the On/Off button and the Home button at the same time for at
    least ten seconds, until the Apple logo appears.
    - Restore from backup. See:                                 
    iOS: How to back up                                                                
    - Restore to factory settings/new iOS device.
    If still problem, make an appointment at the Genius Bar of an Apple store since it appears you have a hardware problem.
      Apple Retail Store - Genius Bar              
    Apple will exchange your iPod for a refurbished one for this price. They do not fix yours.
    Apple - iPod Repair price                       
    A third-party place like the following maybe less. Google for more.
    iPhone Repair, Service & Parts: iPod Touch, iPad, MacBook Pro Screens
    Replace the screen yourself if you are up to it
    iPod Touch Repair – iFixit

  • How do you change the drive that my Iphone backs-up to on my computer?  My first attempt to back-up and i received a pop-up stating that I do not have sufficient memory/space, knowing that I have over 120GB of free space...any ideas? thanks

    How do you change the drive that my Iphone backs-up to on my computer?  My first attempt to back-up and i received a pop-up stating that I do not have sufficient memory/space, knowing that I have over 120GB of free space...any ideas? thanks

    dave0915,
    iTunes stores your iPhone backups in the Library folder in your Home folder.
    iTunes places the backup files in these places:
    Mac: ~/Library/Application Support/MobileSync/Backup/
    Create and delete iPhone, iPad, and iPod touch backups in iTunes
    http://support.apple.com/en-us/HT4946
    Regards,
    Allen

  • How do you use an app that you downloaded on your computer?

    How do you use an app that you down loaded on your computer. I am having trouble because I can download the app just fin but when I actually want to use that app I have no idea what to do. I tried to look for any open buttons but there are none. I downloaded the app on my phone origionaly and I then I downloaded it on my laptop. the app is called arkvpn.

    The apps for the iPhone will not run on Mac

  • HT4847 How do you access your pictures that you stored on icloud from your ipod touch? I lost my ipod touch and want to get my photos from icloud but i cant seem to find any ******* help. where the **** is icloud and how do you get your stored pictures ba

    How do you access your pictures that you stored on icloud from your ipod?

    sunshinecowgill wrote:
    We have three operational computers, one does not have iTunes on it.  Since Apple is saying I have more than 5 authorized computers, and I can't imagine what they are, I am afraid to deauthorize all my computers.  See what I mean?  I just wanted to ask the question about how I can find out WHICH computers Apple thinks I have authorized, so I can decide if it's safe to deauthorize them all or not. 
    You could have more 5 computers authorized if you ever, for example, reformatted a hard drive or replaced a hard drive without deauthorizing the computer first. Apple's system would see that as a different computer, even though you don't. There's nothing to be afraid of in deauthorizing everything and the reauthorizing what you actually have. You won't lose any data. Mistimp is correct, they can't tell you which computers are authorized.

  • How do you get your information, that's on your icloud, something was taken off my notes that should be back-up in my icloud. Help

    How do you get your information, that's on your icloud, something was taken off my notes that should be back-up in my icloud. Help

    The syncing of Notes, isn't a back-up. All it does is to sync Notes to other devices. Whether being a Mac, another iOS device or icloud.com
    This is the same with Contacts, Calendars and what not.
    KOT

  • How do you determine the picture that is shown on iTunes for your podcast?

    How do you determine the picture that is shown on iTunes for your podcast? Is that done in iWeb or Garagetunes?

    That is a supported format,
    Pull the battery while the device is ON, replace after a minute, Let the device reboot 1-3 min,
    see if the problem is fixed,
    If not we may have to reload the device OS to get back the missing option.
    Thanks,
    If you need more info please ask!  If not please resolve the thread using the options by the Kudos’ star, Just place the check in the Post that answered your question, Thanks
    Click Accept as Solution for posts that have solved your issue(s)!
    Be sure to click Like! for those who have helped you.
    Install BlackBerry Protect it's a free application designed to help find your lost BlackBerry smartphone, and keep the information on it secure.

  • How do you untrim a video that won't let you strech it back out to original length?

    How do you untrim a video that was too long to email that won't let you strech it back out to original length?

    Im pretty sure once you trim a video you cant untrim it.

  • TS4253 How do you rotate a photo that is sideways in the photo library on iPad?

    How do you rotate a photo that is sideways in the photo library on the iPad? I have found no solution in the user manual or anywhere else. I simply want to rotate the picture from being sideways to being upright. Doesn't seem like this should be such a mystery. Or am I missing something obvious? Thx

    Thanks folks, I see there are photo editor apps for the iPad. I am downloading one now, and it should work. Good to know I wasn't missing something in the iPad itself. It does not have the capability to rotate or edit pictures without outside help. Thx

  • How do you select an object that is directly under another object?

    How do you select an object that is directly under another object?
    I was working from a template and I wanted to make a text box the same size as a column box that was put there in order to keep the text in the confines of the paper that is was being printed to.
    I could actually put text in each column fine but I wanted it to be in a text box so that I could slightly tilt the test box to compensate for my printer feeding it in slightly wrong. I accomplished this on another template but I could not on this one. If I was working in InDesign or something I know I could just select that layer but I'm at a loss of what to do here. How do I select a column right under a text box? I just thought of something. Once I make the text boxes the same size as the columns I think I can just delete the columns from the inspector. But that would be kind of a work around. I know you can hold down command when nothing is selected from outside the document and then highlight but this is not working. Does anyone have some tips and tricks when it comes to having control over which objects you are selecting when it comes to objects that are overlapped as well as directly over each other.
    Thanks.
    Tim

    I'm not sure it's documented any where, but it's not too difficult. First, ⌘-click outside of the layout area to enter object mode then drag the cursor towards the two objects until you see the handles. Now, again ⌘-click on the top object to deselect it. You can now move the underlying object to the front to edit, delete, etc.
    After typing this, it dawned on me, why not just click the top object to select it & move it to the back? I've only done the other way a bazillion times & now I think of this.

  • How do you change the fields that are displayed on the email preview list after a search?

    How do you modify the fields that are displayed in the mail preview list in the center column of Mac mail after you conduct a search of your email?   All of a sudden the displayed fields changed on me whenever I do a search in mail.   When I have not filtered my email with a search, the default field shown in bold at the top of each message's preview is the "From" field.   However, when I do a search this changes to the "To" field.   Can anyone help?   Thanks, ccarey

    ipicus
    But why would you want this?
    iTunes is responsible for the File Management, let it get on with it, you do your organisation in the iTunes window. And everything you need to do, you can do via the iTunes Window. Want to find the file of a track quickly? Right click on it in the iTunes Window and select Show File: A finder window pops open with the file already selected.
    Regards
    TD

  • TS1363 how do you unlock an Ipod that is disabled?

    how do you unlock an Ipod that is disabled?

    If the iPod is showing the 'disabled' screen due to too many failed passcode attempts then you will need to connect the iPod to the computer that you normally sync to and you should then be able to reset the iPod and re-sync your content to it (http://support.apple.com/kb/HT1212) - you may need to put the iPod into recovery mode : http://support.apple.com/kb/ht1808
    If you do it via a different computer then :
    If you restore on a different computer that was never synced with the device, you will be able to unlock the device for use and remove the passcode, but your data will not be present.

Maybe you are looking for

  • Creation of BP from customer

    am trying to create a BP from custmer in Financial . Have already synchronized BP to Customer and Custmer to BP. am having the following error message: Customer 500002 cannot be assigned to a business partner Message no. CVIC_UI016 Diagnosis No busin

  • Payment Terms at Vendor Subrange Level

    Hi Seniors,     I have a vendor with payment terms 0001 and i have maintained vendor subrange with plant XXXX and payment term 0004 for the same vendor. When i raise a PO with that vendor and plant combination, the system is not picking the plant spe

  • Adding a double line border to a table

    Hi i am creating a PDF form which contains a table, is there a way to set a double line border to to the table in the form ( like the option in EXCLE - i mean border like this: || )  Thanks, Ami

  • Ibook G4 (mid 2005) Bluetooth Issue

    I am having trouble with my bluetooth firmware updater it says "This version of the updater is missing the firmware file cannot proceed". I misplace all of my install discs like a moron. do i need the install discs or can the fix be downloaded.

  • How to pass a where-clause to a procedure

    I have to develop a stored procedure where a part of the where-clause of the select of a cursor depends on the input parameter. My procedure should be something like this: procedure myproc (WHERECLAUSE     in varchar2(100)) is begin declare cursor my