Category Archives: computers/programming

Nerd Alert: Setting up pylint as a Build Tool in Geany

Setup: I’m using the Geany IDE on an Ubuntu system. For this tip, I am just focusing on Python3 files. I can already automagically execute my scripts without leaving the Geany IDE with “Build Execute“, which I is already set … Continue reading

Posted in computers/programming, Uncategorized | Leave a comment

Nerd Alert: Trim trailing LF/CR characters in Oracle

Lots of Nerd Alerts lately, but I haven’t unloaded the camera to see which family pics turned out to be in focus… PROBLEM: Your data has zero or more trailing commas followed by a non-printing character, typically LF/CR. SOLUTION: regexp_replace!

Posted in computers/programming | 2 Comments

Nerd alert: Trimming Leading/Trailing Whitespace with Regular Expressions

Find leading whitespace: ^[ t]+ Find trailing whitespace: [ t]+$

Posted in computers/programming | Leave a comment

Nerd alert: Finding non-printing characters in varchar2 fields in Oracle

How to find non printing characters using instr and regexp_instr in Oracle databases:

Posted in oracle/sqlserver/database | 1 Comment

Nerd alert: deleting blank lines in emacs

Delete blanks lines from an emacs buffer with the flush-lines command: flush-line ^$.  Sweet!

Posted in computers/programming, general | Leave a comment

More Oracle regexp_like

Two more examples of regexp_like for the memory banks: — convert to NULL if SOME_COL is not A,B,C,1,2,or 3 case when (regexp_like(a.SOME_COL,'[^A-C1-3]’)) then NULL else a.SOME_COL end as SOME_COL, — convert to 0000 if the col’s value is not a … Continue reading

Posted in oracle/sqlserver/database | Leave a comment

Numeric validation with Oracle regexp_like

PROBLEM: Identify records where there is non-numeric values for a particular column. SOLUTION: select SOME_COL from SOME_TBL where regexp_like (SOME_COL,’^[^[:digit:]]’) ; Obviously this implies that maybe the field should be a NUMBER datatype to start with, but sometimes what we … Continue reading

Posted in oracle/sqlserver/database | Leave a comment

Custom error pages

Turns out that making custom error pages is really easy: Go ahead and try it out: [broken link] Kind of nice, especially since everything here @ bturnip.com outside of the blog is one big broken link.

Posted in computers/programming | Leave a comment

nerd alert: sethia control code

Note to self: get a sethia/c-with-cedilla in windows with ALT+0199 (Ç)

Posted in computers/programming | Leave a comment

egrep-a-licious

My AIX box doesn’t have GNU grep, so I use egrep on occasion. One liner to find Foo or Bar at the beginning of a line: egrep ^'(Foo|Bar)’ some_file

Posted in computers/programming | Leave a comment