Results 1 to 5 of 5
  1. #1
    Join Date
    Mar 2007
    Posts
    56

    Unanswered: Pervasive SQL equivalent for MSSQL RAISERROR?

    Hey there guys. Not sure where else to go for answers - after google, dbforums has often been my saving grace for MSSQL. However, this time I've had to try and do a trigger using Pervasive SQL -aaaaargh!!! Coming from an MSSQL background I have found this highly frustrating.

    Soooo....
    does anyone know of a Pervasive SQL equivalent for MSSQL RAISERROR? Or perhaps a workaround? I've gone through all the documentation on Pervasive that I can find and I'm just not having any joy.

    Thanks!
    Puppies and cheesecake.

  2. #2
    Join Date
    Dec 2001
    Posts
    1,109
    Provided Answers: 4
    What exactly are you trying to do? There is not direct equivalent to RAISEERROR but there might be a workaround depending on what you are trying to do. Also, what version of PSQL are you using?
    Mirtheil Software
    Certified Pervasive Developer
    Certified Pervasive Technician
    Custom Btrieve/VB development
    http://www.mirtheil.com
    I do not answer questions by email. Please post on the forum.

  3. #3
    Join Date
    Mar 2007
    Posts
    56
    Well I'm trying to interact with a program using Pervasive SQL.

    It is an accounting package where the client does invoicing, but it allows them to duplicate invoice numbers. I've done something similar on MSSQL where I write a trigger to stop the transaction from occurring and then raising an error message on the program that tells the client that he cannot continue as there is a duplicate.

    So basically a trigger to stop the transaction from happening, but telling the client the reason.
    Puppies and cheesecake.

  4. #4
    Join Date
    Dec 2001
    Posts
    1,109
    Provided Answers: 4
    Probably not going to work. PSQL supports triggers but once created, they disable access through the Btrieve interface for that operation (a Delete trigger disables delete operations through Btrieve). It's very possible the accounting software uses Btrieve so the Trigger option won't help.
    It might be worth contacting the vendor of the application to find out if there's an update to the program to prevent duplicate invoice numbers.
    Mirtheil Software
    Certified Pervasive Developer
    Certified Pervasive Technician
    Custom Btrieve/VB development
    http://www.mirtheil.com
    I do not answer questions by email. Please post on the forum.

  5. #5
    Join Date
    Mar 2007
    Posts
    56

    Unfortunately not. The company that does the software say that they make it that way for other reasons/clients. Hence the reason I was asked if I could do something. And having done something similar in MSSQL my boss "naturally" assumes that I can perform miracles in Pervasive SQL.... Oh the uneducated lament of not all SQLs are created equal! :P
    Puppies and cheesecake.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •