Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

JDBC INSERT UPDATE with apostrophe

Featured Replies

  • Newbies

hi

i try to do an insert or update in FMP database by JDBC with a text contains an apostrophe

[color:"red"]

  INSERT INTO table ("fieldtext") VALUES ('d'abord') 

the insert failed mad.gif

How can i put my apostrophe in SQL

i try URLEncode but in filemaker i don't see the caractere ' in my string

somebody have a solution ? smile.gif

The ('d'abord') must be wrong in all languages.

Maybe ("d'abord") or ('d"'"abord') I don't know.

  • Author
  • Newbies

i know it is an example what i try to do

i try lot of things to replace ' in the string

u0027 or %27 or "'" or ' and many

help me

insert value "d'abord"

should work - you will have to search for that character in some middleware though using something like this:

protected static boolean hasEscapeQuotes (String input){

boolean ret = false;

String escape = "';,."/";

for (int i =0 ; i < escape.length(); i++){

char test = escape.charAt(i);

if (input.indexOf(test) != -1) ret = true;

}

return ret;

}

alternatively you can try and use the

escape drive properties

see page 25 of

http://www.filemaker.com.au/downloads/pdf/FMPU55_UltraDev.pdf

i find that these properties are poorly implemented ( if at all ) and it is better to write your own class

sorry that first method will only work to remove the apostrophes

have u tried with prepared statements?

the escape characters are handled automatically

  • 1 month later...

alternatively you can try and use the

escape drive properties

see page 25 of

http://www.filemaker.com.au/downloads/pdf/FMPU55_UltraDev.pdf

The escape property is only use for indentifier (table name, field name ...) not for data. It only use with RAD tools that don't support space or other things in identifier

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.