发个小技术贴

google了半天,发现一帮人问,但没人贴解决方法,结果自己想出来一个。

the question is: there is no instr(x,y) function in sqlite, and for like(x,y), there is also no concat() function to let you add ‘%’ around the x string.
of course you can write your own functions, but there is actually a tricky way to implement instr(x,y).
instr(x,y) is the same to like(replace(quote(x),””,’%'),y)

tag: sqlite, instr

hope this helps 哈哈

______________

硕士论文狂修改中

This entry was posted in 未分类. Bookmark the permalink.

发表评论

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / 更改 )

Twitter picture

You are commenting using your Twitter account. Log Out / 更改 )

Facebook photo

You are commenting using your Facebook account. Log Out / 更改 )

Connecting to %s