Rafine bilgi.Kendime notlar.
Unix, Linux, JBoss, Websphere, Ant, Python, Oracle DB, Arduino, Raspberry Pi.
30 Nisan 2019 Salı
18 Mart 2019 Pazartesi
Python2 - Replace Turkish characters with ascii look-alikes
#!/usr/bin/python -tt
# -*- coding: utf-8 -*-
import codecs
import sys
from base64 import b64encode#reload()
#sys.setdefaultencoding("utf-8")
UTF8Writer = codecs.getwriter('utf8')
sys.stdout = UTF8Writer(sys.stdout)
def TRreplacer(mmm):
my_dict = dict({u'ğ':"g", u'ş':"s", u'ç':"c", u'ü':"u", u'ı':"i", u'ö':"o", u'Ö':"O", u'Ğ':"G", u'Ş':"S", u'Ç':"C", u'Ü':"U", u'İ':"I"})
for items in my_dict:
mmm=mmm.replace(items,my_dict[items])
return mmm
print TRreplacer(u'YİĞİT ÖZEN')
# -*- coding: utf-8 -*-
import codecs
import sys
from base64 import b64encode#reload()
#sys.setdefaultencoding("utf-8")
UTF8Writer = codecs.getwriter('utf8')
sys.stdout = UTF8Writer(sys.stdout)
def TRreplacer(mmm):
my_dict = dict({u'ğ':"g", u'ş':"s", u'ç':"c", u'ü':"u", u'ı':"i", u'ö':"o", u'Ö':"O", u'Ğ':"G", u'Ş':"S", u'Ç':"C", u'Ü':"U", u'İ':"I"})
for items in my_dict:
mmm=mmm.replace(items,my_dict[items])
return mmm
print TRreplacer(u'YİĞİT ÖZEN')
29 Kasım 2018 Perşembe
Oracle - Tablo ya da Kolon ismiyle arama
SELECT owner, table_name, column_name
FROM all_tab_columns
WHERE column_name like '%YOUR_COLUMN_NAME%'
AND OWNER in ('YOUR_SCHEMA_NAME');
FROM all_tab_columns
WHERE column_name like '%YOUR_COLUMN_NAME%'
AND OWNER in ('YOUR_SCHEMA_NAME');
SQL Server Tablo ya da Kolon ismiyle arama
SELECT Table_Name, Column_Name
FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_CATALOG = 'YOUR_DATABASE'
AND COLUMN_NAME LIKE '%YOUR_COLUMN%'
FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_CATALOG = 'YOUR_DATABASE'
AND COLUMN_NAME LIKE '%YOUR_COLUMN%'
10 Nisan 2018 Salı
Kaydol:
Kayıtlar (Atom)