This is a discussion on error: Incorrect database or cursor name format within the Informix forums, part of the Database Server Software category; --> Does anyone have got an idea where I can find a solution for the following problem: I am running ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Does anyone have got an idea where I can find a solution for the following problem: I am running a 4ge-application since years. The database-tables are situated in some different databases. In order to fetch datas to work with them I use the command "DATABASE xyz" to change from the current database arzt to database xyz and "DATABASE arzt" to come back to the first database. This worked fine. Since some time it does not work any more: the following error-message comes: Program stopped at "menues2.4gl", line number 548. SQL statement error number -354. ISAM error number 0. Incorrect database or cursor name format. On this line 548 the command "DATABASE arzt" is situated. But: This error did not occure at every function, that does this command. There are functions with the same command "DATABASE arzt" and it worked. First I thought, I made some mistake in the menues2.4gl-file. But the erormessage comes in functions, which I did not touch in recent weeks. So I would like to get some information over this errormessage. In Google I found only the information that the curser has to have a certain length and so on... but I did not do any changes with that file, that contains the command "Database arzt". with isql the menu-command "Select Database" does work. With the command "database xyz; database arzt" I can change to xyz and back to arzt. When creating a new program with these commands it works. Only in that first programm this command "DATABASE arzt" is beginning to make problems. But not all at once, succesively the problem is rising. First only in one function now in all functions. It seems that there the mistake is not in the sorce-code (4gl). Could it be that there is something overrun, to many open cursors or tomething like that??????? I am not very keen in INFORMIX basically. Does anyone have got an Idea wher I can find the mistake? Thanks Philipp |
| |||
| I am running a 4ge-application since years. The database-tables are situated in some different databases (DATABASE arzt, DATABASE statistik, DATABASE datenalt ). In order to shift old datas to DATABASE datenalt for example I use the command "DATABASE " to change from the current database "arzt" to database "datenalt" and afterwards "DATABASE arzt" to come back to the first database. This worked fine for years. Since some time it does not work any more: the following error-message comes: Program stopped at "menues2.4gl", line number 548. SQL statement error number -354. ISAM error number 0. Incorrect database or cursor name format. On this line 548 the command "DATABASE arzt" is situated. But: This error did not occure at every function, that does this command. There are functions with the same command "DATABASE arzt" and it worked. First I thought, I made some mistake in the menues2.4gl-file. But the erormessage comes in functions, which I did not touch in recent weeks. So I would like to get some information over this errormessage. In Google I found only the information that the curser has to have a certain length and so on... but I have not done any changes with that file, that contains the command "Database arzt". with isql the menu-command "Select Database" does work. With the command "DATABASE datenalt I can change to database datenalt and back to DATABASE arzt. To find out the error I put into various 4ge-programms the same test-lines: DATABASE datenalt PROMPT "Now in DATABASE datenalt" for answer DATABASE arzt PROMPT "Now in DATABASE arzt" for answer And what happened? Some programs can reach up to the second PROMPT "Now in DATABASE arzt" and some programs stop before this message wit the error above. I have no idea, what could be the reason for that. Does anyone kno the solution ? Thanks Philipp Walerdorff > > When creating a new program with these commands it works. > Only in that first programm this command "DATABASE arzt" is beginning to > make problems. But not all at once, succesively the problem is rising. > First only in one function now in all functions. > > It seems that there the mistake is not in the sorce-code (4gl). Could it > be that there is something overrun, to many open cursors or tomething like > that??????? I am not very keen in INFORMIX basically. > > Does anyone have got an Idea wher I can find the mistake? > > Thanks > Philipp |
| ||||
| Philipp Walderdorff wrote: > I am running a 4ge-application since years. The database-tables are > situated in some different databases (DATABASE arzt, DATABASE statistik, > DATABASE datenalt ). In order to shift old datas to DATABASE datenalt for > example I use the command "DATABASE " to change from the current database > "arzt" to database "datenalt" and afterwards "DATABASE arzt" to come back > to the first database. This worked fine for years. And then started breaking? What did you change? Something must have changed - computers are nothing if not relentlessly consistent, and unless you change something, they continue to work as before. > Since some time it does not work any more: the following error-message > comes: > > Program stopped at "menues2.4gl", line number 548. > SQL statement error number -354. > ISAM error number 0. > Incorrect database or cursor name format. Gut feel: you're trying to execute or free statements that are not valid any more - probably because they were associated with a different database. When you change databases, all prepared statements are invalid. It does depend somewhat on how you change database, but your discussion is all about 'DATABASE ThisThatOrTother', and that does invalidate all prepared statements. If you were using CONNECT, then you could maintain the state, but you appear not to be using that functionality - maybe because you're using an older version of I4GL, or because you're unaware of the functionality in the version you are using. > On this line 548 the command "DATABASE arzt" is situated. > > But: This error did not occure at every function, that does this command. > > There are functions with the same command "DATABASE arzt" and it worked. > > First I thought, I made some mistake in the menues2.4gl-file. > But the erormessage comes in functions, which I did not touch in recent > weeks. So, you've been hacking code all over the place? Do you have a version control system in place? (If not, why not!) So, when did it last work reliably? Go back to the version as of some date prior to that, and see that it still works reliably. Then look at all the changes. > So I would like to get some information over this errormessage. > > In Google I found only the information that the curser has to have a > certain length and so on... but I have not done any changes with that file, > that contains the command "Database arzt". > > with isql the menu-command "Select Database" does work. With the command > "DATABASE datenalt I can change to database datenalt and back to DATABASE > arzt. DB-Access does a lot of messing about behind the scenes when you play with database statements. > To find out the error I put into various 4ge-programms the same test-lines: > DATABASE datenalt > PROMPT "Now in DATABASE datenalt" for answer > DATABASE arzt > PROMPT "Now in DATABASE arzt" for answer > > And what happened? Some programs can reach up to the second PROMPT "Now in > DATABASE arzt" and some programs stop before this message wit the error > above. That's odd! Do you add these lines as some extra code at the start, or as some extra code somewhere in the middle, or as the entire program? Changing databases is something that should always be protected with WHENEVER ERROR CONTINUE and followed by your preferred error handling mode - I'd be using WHENEVER ERROR STOP. Which database is current when you execute DATABASE datenalt? > I have no idea, what could be the reason for that. > Does anyone kno the solution ? I don't have enough information yet to know the answer. >>When creating a new program with these commands it works. >>Only in that first programm this command "DATABASE arzt" is beginning to >>make problems. But not all at once, succesively the problem is rising. >>First only in one function now in all functions. >> >>It seems that there the mistake is not in the sorce-code (4gl). Could it >>be that there is something overrun, to many open cursors or tomething like >>that??????? I am not very keen in INFORMIX basically. >> >>Does anyone have got an Idea wher I can find the mistake? Time for you to come clean on some key information that should have been part of your initial question. Which version of I4GL are you using? P-code or C-code? Which version of IDS are you using? Which connection type - shared memory, network, stream pipe (olipcshm, oltlitcp or olsoctcp, olipcstr). Which operating system? Is the database on the same machine as the I4GL programs? If not, we need the platform information for the server too. -- Jonathan Leffler #include <disclaimer.h> Email: jleffler@earthlink.net, jleffler@us.ibm.com Guardian of DBD::Informix v2003.04 -- http://dbi.perl.org/ |