Announcement

Collapse
No announcement yet.

Need new Module_Library_DB function to insert a row into my "shipping" table

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Need new Module_Library_DB function to insert a row into my "shipping" table

    I have this example that adds a row to the s01_BasketCharges table:

    < mvt:assign name="l.basket_charge:basket_id" value="g.Basket:basket_id" />
    < mvt:assign name="l.basket_charge:type" value="'TAX'" />
    < mvt:assign name="l.basket_charge:descrip" value="'Custom Description'" />
    < mvt:assign name="l.basket_charge:amount" value="g.final_tax_calulation" />
    < mvt:assign name="l.basket_charge:disp_amt" value="g.final_tax_calulation" />
    < mvt:assign name="l.basket_charge:tax_exempt" value="0" />
    < mvt:do file="g.Module_Library_DB" name="l.ok" value="BasketCharge_Insert( l.basket_charge )" />

    I would like to modify this code to insert a row into my "shipping" table.
    It appears that I would set a value for each column in my table using the <mvt:assign statement where name = the column name.
    but how should the mvt:do be coded? Will my table have to be added to the g.Module_Library_DB? I would guess so.
    And I'm guessing that the insert function there should be named "shipping_Insert".

    And how do you check the l.ok variable which I'm guessing has the result of the DB function. A 0 or 1 or ?.

    What do I have to do to get a "shipping_Insert" function into the Module_Library_DB?
    Can someone do that for me? I imagine it has to be compiled.

    Thanks, Larry
    Larry
    Luce Kanun Web Design
    www.facebook.com/wajake41
    www.plus.google.com/116415026668025242914/posts?hl=en



    #2
    answered in another thread...
    Bruce Golub
    Phosphor Media - "Your Success is our Business"

    Improve Your Customer Service | Get MORE Customers | Edit CSS/Javascript/HTML Easily | Make Your Site Faster | Get Indexed by Google | Free Modules | Follow Us on Facebook
    phosphormedia.com

    Comment


      #3
      Still looking for someone to build a insert module for us. We need this for our own self created tables. I'd like it generic so that the table name can be supplied to the function, no need for a unique function for each of our tables.
      Last edited by wajake41; 08-31-16, 02:17 PM.
      Larry
      Luce Kanun Web Design
      www.facebook.com/wajake41
      www.plus.google.com/116415026668025242914/posts?hl=en


      Comment

      Working...
      X