Guest User

Untitled

a guest
Nov 24th, 2017
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. var Value = {
  2. ItemName:'Blue Jeans',
  3. Price: 2000,
  4. Quantity:1000
  5. }
  6. //since Id is autoincrement column, so the value will be automatically generated.
  7. Connection.insert({
  8. Into: 'Product',
  9. Values: [Value]
  10. OnSuccess: function(rowsInserted) {
  11. if (rowsInserted > 0) {
  12. alert('successfully added');
  13. }
  14. },
  15. OnError: function(err) {
  16. console.log(err);
  17. alert(err.Message);
  18. }
  19. });
  20. }
Add Comment
Please, Sign In to add comment